import { defAxios as request } from '@/utils/http';

/**
 * 账号/手机号登录
 * @example POST /login/account
 * @param { String } identifier 账号/手机号
 * @param { String } credential 密码
 * @returns
 */
export function login(data) {
	return request({
		url: '/login/account',
		method: 'POST',
		data,
	});
}

/**
 * 退出登录
 * @example POST /logout
 * @returns
 */
export function logout() {
	return request({
		url: '/logout',
		method: 'POST',
	});
}
